<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <meta http-equiv="X-UA-Compatible" content="ie=edge">
    <title>Document</title>
    <style>
        .one{
            width:400px;
            height:400px;
            background-color: red;
            position: relative;
        }
        .two{
            width:100px;
            height:100px;
            background-color: pink;
            position: absolute;
            margin:auto;
            left:0;
            top:0;
            bottom:0;
            right:0;
        }
    </style>
</head>

<body>
    <div class="one">
        <div class="two">
    
        </div>
    </div>
    
</body>

</html>